<template>
  <div>
    <div>当前count的值为：{{$store.state.count}} </div>
  <button @click="handleSub">-1</button>
  </div>
</template>
<script>
export default {
  data () {
    return {}
  },
  methods: {
    handleSub () {
      this.$store.commit('sub', 3)
    }
  }
}
</script>
